package com.jietong.rfid.uhf.command;

public final class R2000Command {
	
	/**
	 * Start Code1
	 */
	public static final byte NET_START_CODE1 = (0x43);
	
	/**
	 * Start Code2
	 */
	public static final byte NET_START_CODE2 = (0x4D);
	
	/**
	 * Old Version Start Code0
	 */
	@Deprecated
	public static final byte COM_START_CODE0 = (0x1B);
	
	/**
	 * Code Length
	 */
	public static final byte HEAD_LENGTH = (0x06);
	
	/**
	 * Antenna configuration data structure length
	 */
	public static final byte ANT_CFG_LENGTH = (36);
	
	/**
	 * Version Length
	 */
	public static final byte VERSION_LENGTH = (16);
	
	/**
	 * Heartbeat Communication
	 */
	public static final byte UHF_ALIVE = (0x10);
	
	/**
	 * Read Tag Data
	 */
	public static final byte UHF_READ_TAG_DATA = (0x26);
	
	/**
	 * Write Tag Data
	 */
	public static final byte UHF_WRITE_TAG_DATA = (0x27);
	
	/**
	 * Read Only Once
	 */
	@Deprecated
	public static final byte UHF_INV_ONCE = (0x25);
	
	/**
	 * Continue Read
	 */
	@Deprecated
	public static final byte UHF_INV_MULTIPLY_BEGIN = (0x2A);
	
	/**
	 * Old Stop Continue Read
	 */
	@Deprecated
	public static final byte UHF_INV_MULTIPLY_END = (0x2B);
	
	/**
	 * Lock Tag
	 */
	public static final byte UHF_LOCK_TAG = (0x2D);
	/**
	 * Kill Tag
	 */
	public static final byte UHF_KILL_TAG = (0x2E);
	/**
	 * Get Version
	 */
	public static final byte UHF_GET_VERSION = (0x31);
	/**
	 * Get Antenna Parameter
	 */
	public static final byte UHF_GET_ANT_CONFIG = (byte) 0xE2; 
	@Deprecated
	public static final byte UHF_GET_ANT_CONFIG_OLD = (0x32);
	/**
	 * Set Antenna Parameter
	 */
	public static final byte UHF_SET_ANT_CONFIG = (byte) 0xE3;
	@Deprecated
	public static final byte UHF_SET_ANT_CONFIG_OLD = (0x33);
	/**
	 * Read Digital Input Status
	 */
	public static final byte UHF_GET_DI_STATE = (0x38);
	/**
	 * Set Digital Output Status
	 */
	public static final byte UHF_SET_DO_STATE = (0x39);
	
	/**
	 * Set up continuous card reading area(0x1B)
	 */
	public static final byte UHF_SET_READ_ZONE = (0x68);
	/**
	 * Set Defaulg epc Area(0x18)
	 */
	public static final byte UHF_SET_DEFAULT_ZONE = (0x66);
	/**
	 * continuous Adjacent to determine time
	 */
	public static final byte UHF_SET_NEIGH_JUDGE = (0x1A);
	/**
	 * Get Password
	 */
	public static final byte UHF_GET_PASSWORD = (0X60);
	/**
	 * Set the read card password(0x1C)
	 */
	// public static final byte UHF_SET_PASSWORD = (0x61);
	/**
	 * Read Device(0x21)
	 */
	public static final byte UHF_GET_DEVICE_NO = (0x62);
	/**
	 * Set Device No(0x20)
	 */
	public static final byte UHF_SET_DEVICE_NO = (0x63);
	/**
	 * Set AB card reading mode(0x1D)
	 */
	public static final byte UHF_SET_AB_MODE = (0x1C);
	/**
	 * Set device clock
	 */
	public static final byte UHF_SET_CLOCK = (0x40);
	/**
	 * Get device clock
	 */
	public static final byte UHF_GET_CLOCK = (0x3F);
	/**
	 * Get Buzzer
	 */
	public static final byte UHF_GET_BUZZ = (0x1D);
	/**
	 * Set Buzzer
	 */
	public static final byte UHF_SET_BUZZ = (0x1E);
	/**
	 * Open Buzzer 43 4D 1E 00 01 00 01 00
	 */
	public static final byte UHF_SET_BUZZ_OPEN = (0x01);
	/**
	 * Close Buzzer 43 4D 1E 00 01 00 00 00
	 */
	public static final byte UHF_SET_BUZZ_CLOSE = (0x00);
	/**
	 * Read tag cache
	 */
	public static final byte UHF_GET_TAG_BUFFER = (0x3A);
	/**
	 * Clear the tag cache
	 */
	public static final byte UHF_RESET_TAG_BUFFER = (0x3B);
	/**
	 * Read frequency range parameters
	 */
	public static final byte UHF_GET_REGION_CONFIG = (0x34);
	/**
	 * Set the frequency range parameters
	 */
	public static final byte UHF_SET_REGION_CONFIG = (0x35);
	/**
	 * Read power mode
	 */
	public static final byte UHF_GET_POWMODE = (0x36);
	/**
	 * Set the power mode
	 */
	public static final byte UHF_SET_POWMODE = (0x37);
	/**
	 * Execute tag private instruction
	 */
	public static final byte UHF_EXE_TAG_SPEC = (0x3C);
	/**
	 * Tag private instruction clears block data
	 */
	public static final byte UHF_ERASE_BLOCK_SPEC = (0x3D);
	/**
	 * Read device statistics
	 */
	public static final byte UHF_GET_STAT = (0x3E);
	/**
	 * Read device extension parameters
	 */
	public static final byte UHF_GET_CONFIGURE = (0x3F);
	/**
	 * Set equipment expansion parameters
	 */
	public static final byte UHF_SET_CONFIGURE = (0x40);
	/**
	 * Set the read card password(0x1C)
	 */
	public static final byte UHF_SET_PASSWORD = (0x12);
	/**
	 * Get the continuous read card area 01 represents the custom read information;00 represents the default EPC information
	 */
	public static final byte UHF_GET_READ_ZONE = (0x16);
	/**
	 * Gets the custom read card parameters
	 */
	public static final byte UHF_GET_READZONE_PARA = (0x18);
	/**
	 * Set the custom read card parameters
	 */
	public static final byte UHF_SET_READZONE_PARA = (0x19);
	/**
	 * Gets the label filter time
	 */
	public static final byte UHF_GET_TAG_FILTER = (0x1A);
	/**
	 * Set the label filter time
	 */
	public static final byte UHF_SET_TAG_FILTER = (0x1B);
	/**
	 * Read the working mode parameters
	 */
	public static final byte UHF_GET_MODE = (0x59);
	/**
	 * Set the working mode of the device, 01 master-slave mode;02 timing mode;03 trigger mode
	 */
	public static final byte UHF_SET_MODE = (0x5A);
	/**
	 * Read trigger delay
	 */
	public static final byte UHF_GET_TRIGGER_TIME = (0x5B);
	/**
	 * Set trigger delay
	 */
	public static final byte UHF_SET_TRIGGER_TIME = (0x5C);
	/**
	 * Gets the output mode to read the automatic output channel parameters
	 */
	public static final byte UHF_GET_OUTPUT = (0x70);
	/**
	 * Set automatic output channel parameters  1 COM 2 NET 3 RS485 4 WIFI/USB->COM
	 */
	public static final byte UHF_SET_OUTPUT = (0x71);
	
	public static final byte UHF_SET_TRIGGER_ALARM = 0x51;

	// ----------------Lock Tag Code Operation And Operation Bock-------------------------------------
	byte UNLOCK = (0x00);
	byte PERMANENCE_WRIALBE = (0x1);
	byte SECURITY_LOCK = (0x2);
	byte PERMANENCE_UNWRIABLE = (0x3);
	// ---------------------------------------------------------------------------
	
	/************************2018-11-30  modified version  start version 2.0*****************************/
	/**
	 * Read Only Once_2018-11-30
	 */
	public static final byte UHF_INV_ONCE_V2 = (byte) (0xE5);
	/**
	 * Start loop card search_2018-11-30
	 */
	public static final byte UHF_INV_MULTIPLY_BEGIN_V2 = (byte) (0xEA);
	/**
	 * Stop circular card searching_2018-11-30
	 */
	public static final byte UHF_INV_MULTIPLY_END_V2 = (byte) (0xEB);
	/**
	 * Read the card seeking mode configuration_2018-11-30
	 */
	public static final byte UHF_GET_INV_PATTERN_CONFIG = (byte) (0x9A);
	/**
	 * Set the card-seeking mode configuration_2018-11-30
	 */
	public static final byte UHF_SET_INV_PATTERN_CONFIG = (byte) (0x9B);
	/**
	 * One key to restore factory Settings_2018-11-30
	 */
	public static final byte UHF_FACTORY_DATA_RESET = (byte) (0x9C);
	/**
	 * Get a multi-card heartbeat_2018-11-30
	 */
	public static final byte UHF_GET_MULTI_CARDL = (byte) 0x8B;
	/**
	 * Set multi-card heartbeat_2018-11-30
	 */
	public static final byte UHF_SET_MULTI_CARDL = (byte) 0x8C;

	/**
	 * Read the card following output data_2018-11-30
	 */
	public static final byte UHF_GET_INV_OUTPUT_DATA = (byte) 0xE8;
	/**
	 * Configure the card following output data_2018-11-30
	 */
	public static final byte UHF_SET_INV_OUTPUT_DATA = (byte) 0xE9;
	/**
	 * Check Antenna_2018-11-30
	 */
	public static final byte UHF_GET_ANT_STATE = (byte) 0x94;
	
	/*******Frequency*********/
	/**
	 * Get Frequency_2018-11-30
	 */
	public static final byte UHF_GET_FREQUENCY = (byte) 0x92;
	/**
	 * Set Frequency_2018-11-30
	 */
	public static final byte UHF_SET_FREQUENCY = (byte) 0x93;
}
